
import time 
from threading import Thread 
from Brain.sensors.ultrasound import UltrasoundModule
from Brain.world import WORLD


global WORKING
WORKING = True

if __name__ == '__main__':
	world = WORLD()
	sensor = UltrasoundModule(world)
	
	def KeyBreak():
		global WORKING
		data = raw_input()
		WORKING = False
	
	t = Thread(target = KeyBreak)
	t.setDaemon(True)

	t.start()
	while WORKING:
		time.sleep(0.4)
		print sensor._pos









